/**  
 *	VisualGroup JavaScript prototype Classes, version 0.1
 *  (c) 2008 Bill Vison <vison_ruan@126.com>
 *
 *
/*--------------------------------------------------------------------------*/
using("Vsg.Component");
using("Vsg.CrossDomainFormPanel");

Vsg.Component.LoginForm = Ext.extend(Vsg.CrossDomainFormPanel,{
	
	constructor:function($opt , $attrs) {
		var $_attrs = {
			id:"Vsg.Component.LoginForm",
			frame:true,
			name:"Vsg.Component.LoginForm",
			border:false,
			defaults:{width:190},
			defaultType:"textfield",
			labelPad:10,
			labelWidth:60
		};

		if ($attrs != null) {
			$_attrs = $attrs;
		}
		
		var $fields = [];
		$fields.push( {fieldLabel:"用户名",name:"j_username",allowBlank:false }  );
		$fields.push(  {fieldLabel:"密 码",name:"j_password",inputType:"password" } );
	
		$_attrs.items = $fields;
		
		Vsg.Component.LoginForm.superclass.constructor.call(this,$_attrs);
	}
});

Vsg.Component.LoginForm.FormException = Ext.extend(Exception.CommonException,{
	name:"Vsg.Component.LoginForm.FormException",
	constructor:function($message , $name ,$value) {
		Vsg.Component.LoginForm.FormException.superclass.constructor.apply(this, arguments);
	}
});
Vsg.Component.LoginForm.FormException.NullUrlError = 1;
Vsg.Component.LoginForm.FormException.SubmitFormError = 1;
